Converter class for Convert FONT which converts Mac fonts to NeXT fonts.
Copyright (C) 1993 David John Burrowes
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
The author, David John Burrowes, can be reached at:
// with the font type in hand, return the proper values...
//
switch (fontType)
{
case 0x9000 :
case 0xB000 :
result = YES;
break;
case 0x9001:
case 0xB001:
[self PutCString: "This font has a `height table\', which Convert FONT can not convert. You can probably convert the font safely, but the converted heights may be wrong." Into: SECOND_RESULT];
result = NO;
break;
case 0x9002:
case 0xB002:
[self PutCString: "This font has a `width table\', Convert FONT can not convert. You can probably convert the font safely, but the converted widths may be wrong." Into: SECOND_RESULT];
result = NO;
break;
case 0x9003:
case 0xB003:
[self PutCString: "This font has both a `width\' and a `height\' table, which Convert FONT can not convert. You can probably convert the font safely, but the character dimensions may be wrong." Into: SECOND_RESULT];
result = NO;
break;
default:
buffer = NewCString(127);
// 93.01.24 djb Compiler doesn't like the %2x and fontType. Not sure why.
// I tried a 0x2324 as a param, and it didn't like that either.
sprintf(buffer, "This may not be a convertable font. Proceed with caution. If you are sure this is a good font, and it fails to convert, give the author this: (%2X)", (unsigned int) fontType);